n, x = map(int, input().split())
x = pow(26, n) - x
s = []
for i in range(n):
    b = x % 26
    x //= 26
    s.append(chr(ord('a') + b))
s.reverse()
print("".join(s), end='')
